using System;
using System.Collections.Generic;
using System.Reflection;
using System.Runtime.InteropServices;

using ILRuntime.CLR.TypeSystem;
using ILRuntime.CLR.Method;
using ILRuntime.Runtime.Enviorment;
using ILRuntime.Runtime.Intepreter;
using ILRuntime.Runtime.Stack;
using ILRuntime.Reflection;
using ILRuntime.CLR.Utils;
using System.Linq;

namespace ILRuntime.Runtime.Generated
{
    unsafe class huqiang_Core_HGUI_RichTextHelper_Binding
    {
        public static void Register(ILRuntime.Runtime.Enviorment.AppDomain app)
        {
            BindingFlags flag = BindingFlags.Public | BindingFlags.Instance | BindingFlags.Static | BindingFlags.DeclaredOnly;
            MethodBase method;
            FieldInfo field;
            Type[] args;
            Type type = typeof(huqiang.Core.HGUI.RichTextHelper);
            args = new Type[]{typeof(System.String)};
            method = type.GetMethod("DeleteLabel", flag, null, args, null);
            app.RegisterCLRMethodRedirection(method, DeleteLabel_0);

            field = type.GetField("Start", flag);
            app.RegisterCLRFieldGetter(field, get_Start_0);
            app.RegisterCLRFieldBinding(field, CopyToStack_Start_0, null);
            field = type.GetField("end", flag);
            app.RegisterCLRFieldGetter(field, get_end_1);
            app.RegisterCLRFieldBinding(field, CopyToStack_end_1, null);
            field = type.GetField("equals", flag);
            app.RegisterCLRFieldGetter(field, get_equals_2);
            app.RegisterCLRFieldBinding(field, CopyToStack_equals_2, null);
            field = type.GetField("sb", flag);
            app.RegisterCLRFieldGetter(field, get_sb_3);
            app.RegisterCLRFieldBinding(field, CopyToStack_sb_3, null);
            field = type.GetField("eb", flag);
            app.RegisterCLRFieldGetter(field, get_eb_4);
            app.RegisterCLRFieldBinding(field, CopyToStack_eb_4, null);
            field = type.GetField("si", flag);
            app.RegisterCLRFieldGetter(field, get_si_5);
            app.RegisterCLRFieldBinding(field, CopyToStack_si_5, null);
            field = type.GetField("ei", flag);
            app.RegisterCLRFieldGetter(field, get_ei_6);
            app.RegisterCLRFieldBinding(field, CopyToStack_ei_6, null);
            field = type.GetField("sSize", flag);
            app.RegisterCLRFieldGetter(field, get_sSize_7);
            app.RegisterCLRFieldBinding(field, CopyToStack_sSize_7, null);
            field = type.GetField("eSize", flag);
            app.RegisterCLRFieldGetter(field, get_eSize_8);
            app.RegisterCLRFieldBinding(field, CopyToStack_eSize_8, null);
            field = type.GetField("sColor", flag);
            app.RegisterCLRFieldGetter(field, get_sColor_9);
            app.RegisterCLRFieldBinding(field, CopyToStack_sColor_9, null);
            field = type.GetField("eColor", flag);
            app.RegisterCLRFieldGetter(field, get_eColor_10);
            app.RegisterCLRFieldBinding(field, CopyToStack_eColor_10, null);
            field = type.GetField("sMaterial", flag);
            app.RegisterCLRFieldGetter(field, get_sMaterial_11);
            app.RegisterCLRFieldBinding(field, CopyToStack_sMaterial_11, null);
            field = type.GetField("eMaterial", flag);
            app.RegisterCLRFieldGetter(field, get_eMaterial_12);
            app.RegisterCLRFieldBinding(field, CopyToStack_eMaterial_12, null);
            field = type.GetField("sQuad", flag);
            app.RegisterCLRFieldGetter(field, get_sQuad_13);
            app.RegisterCLRFieldBinding(field, CopyToStack_sQuad_13, null);
            field = type.GetField("eQuad", flag);
            app.RegisterCLRFieldGetter(field, get_eQuad_14);
            app.RegisterCLRFieldBinding(field, CopyToStack_eQuad_14, null);


            app.RegisterCLRCreateDefaultInstance(type, () => new huqiang.Core.HGUI.RichTextHelper());
            app.RegisterCLRCreateArrayInstance(type, s => new huqiang.Core.HGUI.RichTextHelper[s]);

            args = new Type[]{};
            method = type.GetConstructor(flag, null, args, null);
            app.RegisterCLRMethodRedirection(method, Ctor_0);

        }


        static StackObject* DeleteLabel_0(ILIntepreter __intp, StackObject* __esp, IList<object> __mStack, CLRMethod __method, bool isNewObj)
        {
            ILRuntime.Runtime.Enviorment.AppDomain __domain = __intp.AppDomain;
            StackObject* ptr_of_this_method;
            StackObject* __ret = ILIntepreter.Minus(__esp, 1);

            ptr_of_this_method = ILIntepreter.Minus(__esp, 1);
            System.String @str = (System.String)typeof(System.String).CheckCLRTypes(StackObject.ToObject(ptr_of_this_method, __domain, __mStack), (CLR.Utils.Extensions.TypeFlags)0);
            __intp.Free(ptr_of_this_method);


            var result_of_this_method = huqiang.Core.HGUI.RichTextHelper.DeleteLabel(@str);

            return ILIntepreter.PushObject(__ret, __mStack, result_of_this_method);
        }


        static object get_Start_0(ref object o)
        {
            return huqiang.Core.HGUI.RichTextHelper.Start;
        }

        static StackObject* CopyToStack_Start_0(ref object o, ILIntepreter __intp, StackObject* __ret, IList<object> __mStack)
        {
            var result_of_this_method = huqiang.Core.HGUI.RichTextHelper.Start;
            __ret->ObjectType = ObjectTypes.Integer;
            __ret->Value = (int)result_of_this_method;
            return __ret + 1;
        }

        static object get_end_1(ref object o)
        {
            return huqiang.Core.HGUI.RichTextHelper.end;
        }

        static StackObject* CopyToStack_end_1(ref object o, ILIntepreter __intp, StackObject* __ret, IList<object> __mStack)
        {
            var result_of_this_method = huqiang.Core.HGUI.RichTextHelper.end;
            __ret->ObjectType = ObjectTypes.Integer;
            __ret->Value = (int)result_of_this_method;
            return __ret + 1;
        }

        static object get_equals_2(ref object o)
        {
            return huqiang.Core.HGUI.RichTextHelper.equals;
        }

        static StackObject* CopyToStack_equals_2(ref object o, ILIntepreter __intp, StackObject* __ret, IList<object> __mStack)
        {
            var result_of_this_method = huqiang.Core.HGUI.RichTextHelper.equals;
            __ret->ObjectType = ObjectTypes.Integer;
            __ret->Value = (int)result_of_this_method;
            return __ret + 1;
        }

        static object get_sb_3(ref object o)
        {
            return huqiang.Core.HGUI.RichTextHelper.sb;
        }

        static StackObject* CopyToStack_sb_3(ref object o, ILIntepreter __intp, StackObject* __ret, IList<object> __mStack)
        {
            var result_of_this_method = huqiang.Core.HGUI.RichTextHelper.sb;
            return ILIntepreter.PushObject(__ret, __mStack, result_of_this_method);
        }

        static object get_eb_4(ref object o)
        {
            return huqiang.Core.HGUI.RichTextHelper.eb;
        }

        static StackObject* CopyToStack_eb_4(ref object o, ILIntepreter __intp, StackObject* __ret, IList<object> __mStack)
        {
            var result_of_this_method = huqiang.Core.HGUI.RichTextHelper.eb;
            return ILIntepreter.PushObject(__ret, __mStack, result_of_this_method);
        }

        static object get_si_5(ref object o)
        {
            return huqiang.Core.HGUI.RichTextHelper.si;
        }

        static StackObject* CopyToStack_si_5(ref object o, ILIntepreter __intp, StackObject* __ret, IList<object> __mStack)
        {
            var result_of_this_method = huqiang.Core.HGUI.RichTextHelper.si;
            return ILIntepreter.PushObject(__ret, __mStack, result_of_this_method);
        }

        static object get_ei_6(ref object o)
        {
            return huqiang.Core.HGUI.RichTextHelper.ei;
        }

        static StackObject* CopyToStack_ei_6(ref object o, ILIntepreter __intp, StackObject* __ret, IList<object> __mStack)
        {
            var result_of_this_method = huqiang.Core.HGUI.RichTextHelper.ei;
            return ILIntepreter.PushObject(__ret, __mStack, result_of_this_method);
        }

        static object get_sSize_7(ref object o)
        {
            return huqiang.Core.HGUI.RichTextHelper.sSize;
        }

        static StackObject* CopyToStack_sSize_7(ref object o, ILIntepreter __intp, StackObject* __ret, IList<object> __mStack)
        {
            var result_of_this_method = huqiang.Core.HGUI.RichTextHelper.sSize;
            return ILIntepreter.PushObject(__ret, __mStack, result_of_this_method);
        }

        static object get_eSize_8(ref object o)
        {
            return huqiang.Core.HGUI.RichTextHelper.eSize;
        }

        static StackObject* CopyToStack_eSize_8(ref object o, ILIntepreter __intp, StackObject* __ret, IList<object> __mStack)
        {
            var result_of_this_method = huqiang.Core.HGUI.RichTextHelper.eSize;
            return ILIntepreter.PushObject(__ret, __mStack, result_of_this_method);
        }

        static object get_sColor_9(ref object o)
        {
            return huqiang.Core.HGUI.RichTextHelper.sColor;
        }

        static StackObject* CopyToStack_sColor_9(ref object o, ILIntepreter __intp, StackObject* __ret, IList<object> __mStack)
        {
            var result_of_this_method = huqiang.Core.HGUI.RichTextHelper.sColor;
            return ILIntepreter.PushObject(__ret, __mStack, result_of_this_method);
        }

        static object get_eColor_10(ref object o)
        {
            return huqiang.Core.HGUI.RichTextHelper.eColor;
        }

        static StackObject* CopyToStack_eColor_10(ref object o, ILIntepreter __intp, StackObject* __ret, IList<object> __mStack)
        {
            var result_of_this_method = huqiang.Core.HGUI.RichTextHelper.eColor;
            return ILIntepreter.PushObject(__ret, __mStack, result_of_this_method);
        }

        static object get_sMaterial_11(ref object o)
        {
            return huqiang.Core.HGUI.RichTextHelper.sMaterial;
        }

        static StackObject* CopyToStack_sMaterial_11(ref object o, ILIntepreter __intp, StackObject* __ret, IList<object> __mStack)
        {
            var result_of_this_method = huqiang.Core.HGUI.RichTextHelper.sMaterial;
            return ILIntepreter.PushObject(__ret, __mStack, result_of_this_method);
        }

        static object get_eMaterial_12(ref object o)
        {
            return huqiang.Core.HGUI.RichTextHelper.eMaterial;
        }

        static StackObject* CopyToStack_eMaterial_12(ref object o, ILIntepreter __intp, StackObject* __ret, IList<object> __mStack)
        {
            var result_of_this_method = huqiang.Core.HGUI.RichTextHelper.eMaterial;
            return ILIntepreter.PushObject(__ret, __mStack, result_of_this_method);
        }

        static object get_sQuad_13(ref object o)
        {
            return huqiang.Core.HGUI.RichTextHelper.sQuad;
        }

        static StackObject* CopyToStack_sQuad_13(ref object o, ILIntepreter __intp, StackObject* __ret, IList<object> __mStack)
        {
            var result_of_this_method = huqiang.Core.HGUI.RichTextHelper.sQuad;
            return ILIntepreter.PushObject(__ret, __mStack, result_of_this_method);
        }

        static object get_eQuad_14(ref object o)
        {
            return huqiang.Core.HGUI.RichTextHelper.eQuad;
        }

        static StackObject* CopyToStack_eQuad_14(ref object o, ILIntepreter __intp, StackObject* __ret, IList<object> __mStack)
        {
            var result_of_this_method = huqiang.Core.HGUI.RichTextHelper.eQuad;
            return ILIntepreter.PushObject(__ret, __mStack, result_of_this_method);
        }



        static StackObject* Ctor_0(ILIntepreter __intp, StackObject* __esp, IList<object> __mStack, CLRMethod __method, bool isNewObj)
        {
            ILRuntime.Runtime.Enviorment.AppDomain __domain = __intp.AppDomain;
            StackObject* __ret = ILIntepreter.Minus(__esp, 0);

            var result_of_this_method = new huqiang.Core.HGUI.RichTextHelper();

            return ILIntepreter.PushObject(__ret, __mStack, result_of_this_method);
        }


    }
}
